﻿<UserControl x:Class="JAAF.UI.WPF.RoundedBox"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             mc:Ignorable="d" 
             d:DesignHeight="300" d:DesignWidth="300">

    <UserControl.ContentTemplate>
        <DataTemplate>
            <Border CornerRadius="12,12,12,12" Background="#99FFFFFF" Opacity="0.9" VerticalAlignment="Stretch">
                <Grid>
                    <Grid Margin="-6,-5,-12,-13">
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="20"/>
                            <ColumnDefinition Width="*"/>
                            <ColumnDefinition Width="27"/>
                        </Grid.ColumnDefinitions>
                        <Grid.RowDefinitions>
                            <RowDefinition Height="20"/>
                            <RowDefinition Height="*"/>
                            <RowDefinition Height="27"/>
                        </Grid.RowDefinitions>

                        <Image Height="20" Width="20" Source="../Resources/shadow_tl.png" Stretch="Fill"/>
                        <Image Height="20" Grid.Column="1" Source="../Resources/shadow_t.png" Stretch="Fill"/>
                        <Image Height="20" Width="27" Grid.Column="2" Source="../Resources/shadow_tr.png" Stretch="Fill"/>
                        <Image Width="27" Grid.Column="2" Grid.Row="1" Source="../Resources/shadow_r.png" Stretch="Fill"/>
                        <Image Width="20" Grid.Row="1" Source="../Resources/shadow_l.png" Stretch="Fill"/>
                        <Image Height="27" Grid.Column="1" Grid.Row="2" Source="../Resources/shadow_b.png" Stretch="Fill" />
                        <Image Height="27" Width="20" Grid.Row="2" Source="../Resources/shadow_bl.png" Stretch="Fill"/>
                        <Image Height="27" Width="27" Grid.Column="2" Grid.Row="2" Source="../Resources/shadow_br.png" Stretch="Fill"/>

                        <ContentPresenter Grid.Row="1" Grid.Column="1" Opacity="1" Content="{TemplateBinding Content}" />

                    </Grid>



                </Grid>
            </Border>
        </DataTemplate>
    </UserControl.ContentTemplate>

</UserControl>
